sentences
Type
keyword
Summary
Used with the number functionto designate parts of a string delimited by Unicode sentence breaks, as determined by the ICU Library.
Syntax
sentences
Description
Use the sentences keyword to count the number of sentences in a container.
A sentence is a chunk delimited by Unicode sentence breaks, as determined by the ICU Library.
note
The sentence chunk includes the punctuation mark at the end of the sentence, if there is one. It will also include any trailing spaces. The rules describing Unicode sentence breaks are available at http://www.unicode.org/reports/tr29/#Sentence_Boundaries
Examples
put "This is the first sentence. This is the second sentence." into tText
put the number of sentences in tText -- returns 2
put "The green apple costs $0.50, the red apple costs $0.60. Which one should I buy?" into tText
put the number of sentences in tText -- returns 2
Related
control structure: function
function: number
glossary: keyword
keyword: sentence
Compatibility and Support
Introduced
LiveCode 7.0
OS
mac
windows
linux
ios
android
Platforms
desktop
server
mobile